<script lang="ts">
import { defineComponent } from "vue";
import { useStore } from "@/store";
import HomeList from './components/homeList.vue'
import { IRoomListParams } from "@/api/interface";

export default defineComponent({
  components:{
    HomeList
  },
  setup() {

  },
  asyncData({ store, route }: any) {
    console.log("asyncData==", store, route);
    const {pageNo} = store.state
    return store.dispatch("getRoomList",{ pageNo} as IRoomListParams);
  }
});

// asyncData(){

// }
</script>

<template>
  <div class="home-page">
    <!-- banner -->
    <div class="banner"></div>
    <!-- 房屋列表 -->
    <div class="main-wrapper">
      <h2 class="title">主标题</h2>
      <p class="sub-title">副标题</p>
      <HomeList />
    </div>
  </div>
</template>

<style lang="scss">
@import "@/assets/scss/home/index.scss";
</style>
